package com.guilin.mapper;

import com.guilin.domain.ForumLikeRecord;
import org.apache.ibatis.annotations.Param;

public interface ForumLikeRecordMapper {

    /**
     * 插入点赞记录
     * @param record
     * @return
     */
    int insert(ForumLikeRecord record);


    /**
     * 删除点赞记录
     * @param threadId
     * @param userId
     * @return
     */
    int deleteByThreadAndUser(@Param("threadId") Long threadId, @Param("userId") Long userId);


    /**
     * 查询点赞记录
     * @param threadId
     * @param userId
     * @return
     */
    int countByThreadAndUser(@Param("threadId") Long threadId, @Param("userId") Long userId);
}
